﻿using DTOModels.User;

namespace BusinessInterface
{
    public interface IUserManagerService:IBaseService
    {
        /// <summary>
        /// 登录成功查询到的用户信息
        /// </summary>
        /// <param name="userName"></param>
        /// <param name="password"></param>
        /// <returns></returns>
        public SysUserInfo? Login(string userName, string password);

        /// <summary>
        /// 获取所有的菜单和按钮数据
        /// </summary>
        /// <param name="userId"></param>
        /// <returns></returns>
        public Task<(List<UserMenuBtnDto>, List<Guid>)> GetAllMenuBtnTreeListAsync(int userId);


        /// <summary>
        /// 设置用户菜单和按钮
        /// </summary>
        /// <param name="setUserMenueModel"></param>
        /// <returns></returns>
        public Task<bool> SetUserMenuAndBtnAsync(SetUserMenuBtnDto setUserMenueModel);


        /// <summary>
        /// 实时校验用户的按钮权限
        /// </summary>
        /// <param name="userId"></param>
        /// <param name="btnValue"></param>
        /// <returns></returns>
        public Task<bool> ValidateBtnAsync(int userId, string btnValue);
    }
}
